#pragma once
#ifndef SMPPDATASM_HPP
#define SMPPDATASM_HPP

#include "SMPPHeader.hpp"
#include "SMPPMessageSubmissionRequestTLVs.hpp"

namespace smpp {
namespace pdu{

class SMPP_DLLPRFX DataSM : public Header, 
	public MessageSubmissionRequestTLVs{
		CoctetString _ServiceType;
		quint8 _SourceAddrTON;
		quint8 _SourceAddrNPI;
		CoctetString _SourceAddr;
		quint8 _DestAddrTON;
		quint8 _DestAddrNPI;
		CoctetString _DestAddr;
		quint8 _EsmClass;
		quint8 _RegisteredDelivery;
		quint8 _DataCoding;
public:
	DataSM(const Header &,
		const CoctetString &nServiceType = "",
		const quint8 nSourceAddrTON = 0,
		const quint8 nSourceAddrNPI = 0,
		const CoctetString &nSourceAddr = "",
		const quint8 nDestAddrTON = 0,
		const quint8 nDestAddrNPI = 0,
		const CoctetString &nDestAddr = "",
		const quint8 nEsmClass = 0,
		const quint8 nRegisteredDelivery = 0,
		const quint8 nDataCoding = 0,
		const MessageSubmissionRequestTLVs &
		nMessageSubmissionRequestTLVs = MessageSubmissionRequestTLVs());

	DataSM(const DataSM &);

	void setServiceType(const CoctetString &);

	const CoctetString &getServiceType() const;

	void setSourceAddrTON(const quint8);

	const quint8 getSourceAddrTON() const;

	void setSourceAddrNPI(const quint8);

	const quint8 getSourceAddrNPI() const;

	void setSourceAddr(const CoctetString &);

	const CoctetString &getSourceAddr() const;

	void setDestAddrTON(const quint8);

	const quint8 getDestAddrTON() const;

	void setDestAddrNPI(const quint8);

	const quint8 getDestAddrNPI() const;

	void setDestAddr(const CoctetString &);

	const CoctetString &getDestAddr() const;

	void setEsmClass(const quint8);

	const quint8 getEsmClass() const;

	void setRegisteredDelivery(const quint8);

	const quint8 getRegisteredDelivery() const;

	void setDataCoding(const quint8);

	const quint8 getDataCoding() const;

	void calcCommandLength();
};

}
}

#endif
